<template>
  <view>
    <text class="loading-box" v-if="isShowLoading">
      <u-loading mode="circle" size="150" color="#2b85e4"></u-loading>
      <view class="text">页面加载中，请稍后···</view>
    </text>
  </view>
</template>

<script>
import { mapGetters } from "vuex";
export default {
  data() {
    return {};
  },
  computed: {
    ...mapGetters(["isShowLoading"]),
  },
  mounted() {
    console.log('wgs84')
    uni.getLocation({
      type: 'wgs84',
      isHighAccuracy:true,
      accuracy: 'best',
      success: ((res)=> {
        console.log('当前位置的经度：' ,res);
      })
    });
    // uni.getLocation({
    //   type: 'gcj02',
    //   isHighAccuracy:true,
    //   geocode:true,
    //   accuracy: 'best',
    //   success: ((res)=> {
    //     console.log(res)
    //   })
    // })
  }
};
</script>

<style lang="scss" scoped>
.loading-box {
  position: fixed;
  left: 50%;
  top: 50%;
  transform: translate(-50%, -50%);
  text-align: center;

  .text {
    margin-top: 10px;
  }
}
</style>
